<?php
/**
 * Created by PhpStorm.
 * User: krystal
 * Date: 2019/4/4
 * Time: 13:46
 */

namespace app\common\validate;


use think\Validate;

/**
 *
 * Class ValidteForTeach
 * @package app\common\validate
 */
class VideoForTeach extends Validate
{
    protected $rule = [
        'cid' => 'require|number|gt:0',
        'csid' => 'require|number|gt:0',
        'progress' => 'require|number',
    ];

    protected $message = [];

    protected $scene = [
        'save_section_progress' => [
            'cid',
            'csid',
            'progress'
        ],
        'save_section_exercise_progress' => [
            'csid'
        ]
    ];

    protected $field = [
        'cid' => '课程id',
        'csid' => '章节id',
        'progress' => '进度时间,例如:855'
    ];
}